home *** CD-ROM | disk | FTP | other *** search
/ The Original Shareware 1.1 / The Original Shareware (WeMake CDs)(Volume 1.1)(CDs, Inc)(1993).iso / 8 / ct26.zip / CT26.DOC next >
Text File  |  1991-05-24  |  11KB  |  225 lines

  1.                                  Cache Test v 2.6
  2.                                        by
  3.                                   George Spafford
  4.  
  5.                                      Summary
  6.  
  7.           This program is designed to help a user evaluate the impacts
  8.           of a cache, or the changes to an existing cache, on a drive's
  9.           performance.  
  10.  
  11.       Furthermore, with users' increasingly using caches during a 
  12.       variety of tasks, it is important to find the optimal cache 
  13.       settings given the task at hand.  Whereas a word processor 
  14.       might make heavy usage of sequential files, a database 
  15.       might make heavy usage of random access files.  With this 
  16.       in mind, the memory requirements, sectors cached, write 
  17.       delays and so forth have many possible variations.
  18.  
  19.           By default, Cache Test creates a 10,000 record sequential file
  20.           using 32 byte records and then a 10,000 record random access file
  21.           that again uses 32 byte record lengths.  Note, even if the default is
  22.           changed, any sample string length will be increased by two bytes by
  23.           the addition of a CR/LF.  You may want to compensate accordingly if
  24.           you wish to be exact in your measurements.  The sample record size
  25.           indicator displays the TRUE sample string size.
  26.  
  27.       This program uses BIOS to do all of its reads and writes, 
  28.       so any hardware or software cache should be able to get 
  29.       some good "hits."  In attempt to flush caches during the 
  30.       test, files are frequently opened and closed.
  31.  
  32.           All of the times that this program writes are the result of
  33.           subtracting the beginning time from the ending time.  Nothing
  34.           fancy, so the values are relatively accurate.  Note, if you do
  35.           some math to compute access times per record, you will run into
  36.           the age old problem of significant digits.  This program does not
  37.           account for any decimal positions.  As such, if you try to take the
  38.           timings out to 1/10th of a second, the resulting error factor can be
  39.           quite high.  You will probably notice times when the Total Time does
  40.           not equal the summation of the two measured times.  This is because
  41.           the overall time is on a unique timer and not the other two values
  42.           simply added together.  (You will also witness this on the test level
  43.           where the total time for the random tests does not match the sum of
  44.           the individual scores.  The same holds true for the sequential tests.)
  45.           
  46.           A few definitions:
  47.  
  48.           "ButterFly Test"     The middle record is read and then a
  49.                                record is alternatingly and read in each
  50.                                direction from the middle.  Say you have
  51.                                a 100 record file, the read order would
  52.                                be 50,49,51,48,52,47,53 . . . and so
  53.                                forth.
  54.  
  55.           "CR/LF"              Carriage Return and Line Feed.  Decimal 13
  56.                                and 10 respectively (CHR$(13),CHR$(10)).  These
  57.                                two characters are used as "end of record"
  58.                                delimitters.  As such, they are included in the
  59.                                byte count when a record is written.  If the
  60.                                sample string is 10 bytes, these two additional
  61.                                bytes are added to the end resulting in a total
  62.                                of 12 bytes.  Bear this in mind if you want exact
  63.                                values.
  64.                                
  65.           "Crescendo Read"     Records are read alternatingly in from the end of
  66.                                the file and the beginning file.  This is to say,
  67.                                record 1, 10000, 2, 9999, 3, 9998, 4, 9997 etc.
  68.  
  69.           "Random Read/Write"  Random functions generate independent random
  70.                                reads and writes.
  71.  
  72.           "Stepping-by-1"      A random access file's records are being accessed
  73.                                one at a time.
  74.  
  75.           "Stepping-by-10"     A random access file's records are being accessed
  76.                                on every 10th record.
  77.  
  78.           "Write-by-10"        A random access file's records are being updated
  79.                                on every 10th record.
  80.  
  81.           "Overall"            This is the total time of all tests AND file
  82.                                deletes.  So, it might not reflect the sum
  83.                                of all tests exactly, but it should be very
  84.                                close.
  85.  
  86.           I just wanted to make those meanings a little clearer.
  87.  
  88.           ******************************************************************
  89.  
  90.           Usage of this program is:
  91.  
  92.           CT  </D:d><F:bbb></N:nnn></S></R></B></?>
  93.  
  94.               CT by itself will clear the screen and then ask you for the
  95.               desired drive and then proceed using a 10,000 record 
  96.               default.  It will NOT prompt the user for any other settings.
  97.               
  98.       Explanation of switches:
  99.  
  100.           /D:d    This specifies "d" as the drive to be tested.
  101.  
  102.           /F:b  This specifies the number of fixed bytes per record.
  103.                 It must be between 1 and 32,765.  The default is 32 bytes.
  104.                 Use this with the /N:n switch to enhance your testing.
  105.                 (Because of CR/LF usage in the file structure, the logical
  106.                 limit for a user input is 32,765 and not the allowable
  107.                 32,767)
  108.  
  109.       /N:n    This specifies the number of test records.
  110.         Note, the only limitation here is the available space 
  111.                 on your test drive.  You can also go as small as
  112.         you want, but you will reach a point where your test
  113.         will lose its validity.
  114.                 The default value, if this switch is not used, is
  115.                 10,000 records.
  116.  
  117.       /B    Test both sequential and random access records.
  118.       /R    Test random access records only.
  119.       /S    Test sequential access records only.
  120.  
  121.           Suggestions:
  122.  
  123.           You might want to set up a batch file that purges your cache
  124.           before CT is run.  This will allow the cache to have a little
  125.           fairer test, as opposed to starting out partially full.
  126.           Also, if you are interested in the actual hits on your cache, most
  127.           cache programs (PC-CACHE and NCACHE for sure) have status switches
  128.           that allow you to see the results from the cache's point of view.
  129.  
  130.           The test file is written in the root directory of the target drive.
  131.           The file name is TEST$$CT.SPD.  If the critter appears, don't panic!
  132.           It probably didn't get deleted because of an interrupted test.
  133.  
  134.       HISTORY:
  135.  
  136.           V2.6  5/24/91
  137.  
  138.                 I honestly did not intend another update so soon.  It was
  139.                 pointed out to me that the file structure that I had been
  140.                 using was variable.  As such, it made ratio comparisons
  141.                 somewhat difficult.  Now, the default fixed record length
  142.                 is 32 bytes (the test record count is still 10,000).  The
  143.                 user can specify the record length by using the /F:bbbbb
  144.                 switch.  "bbbbb" must be between 0 and 32,765.   Since the
  145.                 values are now fixed, a user can do a little math (remember
  146.                 that subject folks??) and discern the records per second and
  147.                 so forth.  Do note, that two bytes are added to the test string
  148.                 in the files (CR/LF to be exact) that is why the maximum byte
  149.                 size that a user can specify is 32,765 and not the 32,767 legal
  150.                 default limit.
  151.               
  152.           V2.5  5/22/91
  153.  
  154.                 1.  An actual test file byte size field has been added.
  155.                     This should allow users to track the actual sizes of
  156.                     the test records being written.
  157.                 2.  Some users suggested that truly random reads and writes
  158.                     should be added.  This serves to get away from any form
  159.                     of sequentialized data.
  160.                 3.  Again, more cosmetic touchups.
  161.  
  162.       V2.0    5/16/91
  163.  
  164.                 Due to some users having limited drive space, switches
  165.         were added to allow for different size tests to 
  166.         occur.  I was somewhat hesitant to do this because it
  167.         negated the ability to call results "standard," but 
  168.         what really is standard?
  169.  
  170.         Switches were also added to allow users to select 
  171.         what tests they want to run.  For now, all that can 
  172.         be specified is whether or not to run all tests, 
  173.         sequential tests only, or random tests only.
  174.  
  175.         The ButterFly test was also added in an attemp to 
  176.         give look-ahead caches a hard time.  Some of the 
  177.         caches that use a FIFO method of purging will have a 
  178.         heck of a time with this one.
  179.  
  180.         Added timers/cleared up timers for the sequential and 
  181.         overall tests.  Also speaking of timers, to avoid 
  182.         slowing down some routines, I have removed some of 
  183.         the video effects that were for the user's benefit 
  184.         only.
  185.  
  186.         Special thanks to Jonathan Fisk for all of his 
  187.         suggestions and debugging efforts.
  188.  
  189.         Special thanks also go out to Tim Akright, the sysop 
  190.         of Queued Access for all of his support.
  191.  
  192.  
  193.       V1.0  5/10/91
  194.  
  195.                 Well, I released it.  That pretty well sums it up.
  196.  
  197.  
  198.         I hope this program helps you evaluate some of your problems
  199.         or even makes some solutions/benefits clear.  This program is
  200.         released as shareware.  Its price is $5 for each concurrently
  201.         used copy.  If you have any suggestions or comments, I'd REALLY
  202.         like to hear those too.
  203.  
  204.             Sincerely,
  205.  
  206.             George Spafford
  207.             3001 LakeShore Drive, #329
  208.             St. Joseph, MI 49085
  209.  
  210.             Data:  (616) 468-5026  Queued Access BBS 2400-8-N-1
  211.                                    FIDOnet: 1:227/250
  212.  
  213.  
  214.         And now for the unpleasantries:
  215.         
  216.         CT IS DISTRIBUTED AS IS.  THE AUTHOR (GEORGE SPAFFORD) MAKES NO
  217.         WARRANTY OF ANY KIND, EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED
  218.         TO WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE,
  219.         WITH RESPECT TO THIS SOFTWARE AND DOCUMENTATION. IN NO EVENT SHALL
  220.         THE AUTHOR BE LIABLE FOR ANY DAMAGES, INCLUDING LOST PROFITS, LOST
  221.         SAVINGS, OR ANY OTHER INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
  222.         OUT OF THE USE OF OR THE INABILITY TO USE THIS PROGRAM.
  223.         ----------------------------------------------------------------
  224.         
  225.